//@ sourceURL=CheckStateView.js
Ext.ns("CheckStateView");

CheckStateView = Ext.extend(Ext.Panel,{
    constructor : function(a) {
        Ext.applyIf(this, a);
        var all=this.initUIComponents();
        CheckStateView.superclass.constructor.call(this, {
            id : "CheckStateView",
            region : "center",
            layout : "border",
            border : false,
            iconCls : "menu-position",
            items : [all.yearGridPanel,all.yearGridSearchPanel]
        });
    },
    initUIComponents : function() {
    var yearGridComponents=new creategridview({
        topbar : {
            inputFormName : 'CheckStateForm',
            topbarAdd:{
                hidden:false
            },
            topbarDel:{
                hidden:false
            }
        },
       search : {
            items : [ {
                style : "margin:5px 5px 5px 5px;",
                text : "负责人"
            }, {
                columnWidth : 0.2,
                xtype : "textfield",
                name : "Q_checkLeader_S_LK",
                maxLength : 256
            } ]
        },
        grid : {
            title : "检查情况列表",
            rowActions:true,
            listUrl : __ctxPath + "/safecheckplan/listCheckState.do?Q_checkId_L_EQ="+this.checkId,
            removeUrl : __ctxPath + "/safecheckplan/deleteCheckState.do",
            fields : [ "id","checkPart","checkStartDate","state", "checkId","checkLeader","member"],
            columns : [ {
                header : "id",
                dataIndex : "id",
                hidden : true
            },{
                header : "检查部位",
                dataIndex : "checkPart",
                width:80
            },{
                header : "检查时间",
                dataIndex : "checkStartDate",
                width:70
            },{
                header : "检查负责人",
                dataIndex : "checkLeader",
                width:80
            },{
                header : "负责人",
                dataIndex : "member",
                width:80
            },{
                header : "检查状态",
                dataIndex : "state",
                width:80
            }]
        },
        formCfg : {
        	checkId : this.checkId
        }
        
    });
    return yearGridComponents;
}
});

